package com.lzdongrui.backend.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.lzdongrui.common.annotation.Excel;
import com.lzdongrui.common.core.domain.BaseEntity;

/**
 * 学期对象 semester
 * 
 * @author hjs
 * @date 2023-05-04
 */
@Data
public class Semester extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** id */
    private Long id;

    /** 学年 */
    @Excel(name = "学年")
    private Integer schoolYear;

    /** 学期名字 */
    @Excel(name = "学期名字")
    private String name;

    /** 开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date startTime;

    /** 结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date endTime;

    /** 是否为当前学期 */
    @Excel(name = "是否为当前学期")
    private Integer current;

    /** 操作人 */
    @Excel(name = "操作人")
    private Long operator;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setSchoolYear(Integer schoolYear) 
    {
        this.schoolYear = schoolYear;
    }

    public Integer getSchoolYear() 
    {
        return schoolYear;
    }
    public void setName(String name) 
    {
        this.name = name;
    }

    public String getName() 
    {
        return name;
    }
    public void setStartTime(Date startTime) 
    {
        this.startTime = startTime;
    }

    public Date getStartTime() 
    {
        return startTime;
    }
    public void setEndTime(Date endTime) 
    {
        this.endTime = endTime;
    }

    public Date getEndTime() 
    {
        return endTime;
    }
    public void setCurrent(Integer current) 
    {
        this.current = current;
    }

    public Integer getCurrent() 
    {
        return current;
    }
    public void setOperator(Long operator) 
    {
        this.operator = operator;
    }

    public Long getOperator() 
    {
        return operator;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("schoolYear", getSchoolYear())
            .append("name", getName())
            .append("startTime", getStartTime())
            .append("endTime", getEndTime())
            .append("current", getCurrent())
            .append("operator", getOperator())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
